package pl.mess.core.tags.elements;

import pl.mess.core.tags.writer.MESSXmlWriter;
import pl.mess.core.tags.ifc.ControlAttribute;
import pl.mess.core.uiobjects.MESSTreeViewElement;

import java.util.List;
import java.util.ArrayList;

/**
 * Created by IntelliJ IDEA.
 * User: gibffe
 * Date: Apr 4, 2006
 * Time: 8:21:46 PM
 * To change this template use File | Settings | File Templates.
 */
public class MESSTreeViewElementTag extends MESSBaseTag {

    private static final String TAG_NAME = "treeElement";

    /**
     * tree element name (label)
     */
    @ControlAttribute public String label = null;

    /**
     * tree element description
     */
    @ControlAttribute public String nodeDescription = null;



    /**
     * Return tag name
     * @return
     */
    public String getTagName() {
        return TAG_NAME;
    }

    /**
     * Public constructor
     * @param writer
     */
    public MESSTreeViewElementTag(MESSXmlWriter writer, MESSTreeViewElement element) {
        // init tag object
        this.setWriter(writer);
        this.setLabel(element.getElementName());
        this.setNodeDescription(element.getNodeDescription());
    }



    
    // property: label
    public String getLabel() {
        return label;
    }

    public void setLabel(String label) {
        this.label = label;
    }

    // property:  nodeDescription

    public String getNodeDescription() {
        return nodeDescription;
    }

    public void setNodeDescription(String nodeDescription) {
        this.nodeDescription = nodeDescription;
    }
}
